-
Notifications
You must be signed in to change notification settings - Fork 221
Conversation
@@ -41,6 +41,7 @@ function onEventFinish(player, csid, option) | |||
if csid == 521 and player:getQuestStatus(SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER) == QUEST_AVAILABLE then | |||
player:addQuest(SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER) | |||
elseif csid == 516 then | |||
npcUtil.completeQuest(player, SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {ki = tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp = 2000}) | |||
npcUtil.completeQuest(player, SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {ki = tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp = 2000 * EXP_RATE}) | |||
player:messageSpecial(ID.text.KEYITEM_OBTAINED, tpz.ki.MAP_OF_KING_RANPERRES_TOMB) -- Map of King Ranperre's Tomb |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
npcUtil isn't displaying the message because the table key it expects inside the rewards table is keyItem
instead of ki
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ibm2431 https://github.com/project-topaz/topaz/blob/release/scripts/globals/keyitems.lua#L3011
tpz.ki
is equivalent to tpz.keyItem
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Xephera looks like npcUtil.completeQuests() already has exp rate baked in:
topaz/scripts/globals/npc_util.lua
Line 372 in 8985d2a
player:addExp(params["xp"] * EXP_RATE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The enums are equivalent, but the table that npcUtil.completeQuest takes is not~
if params["keyItem"] ~= nil then
npcUtil.giveKeyItem(player, params["keyItem"])
end
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I misunderstood table, thinking ki is a table (because our "enums" are tables) and totally missed that the argument input here is its own table.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it's confusing. Wondering if npcUtil functions should be tweaked to accept both "ki" and "keyItem" as field names.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fixed the exp_rate thing but it doesn't give a key item notification regardless for whatever reason so I'm leaving that part in until we know why.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
npcUtil.completeQuest(player, SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {keyItem = tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp = 2000 * EXP_RATE})
didn't work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just gonna second that
player:messageSpecial(ID.text.KEYITEM_OBTAINED, tpz.ki.MAP_OF_KING_RANPERRES_TOMB) -- Map of King Ranperre's Tomb
shouldn't be needed if you change
npcUtil.completeQuest(player, SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {ki = tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp = 2000})
to
npcUtil.completeQuest(player, SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {keyItem = tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp = 2000})
notice the change from ki = tpz.ki.MAP_OF_KING_RANPERRES_TOMB
to keyItem = tpz.ki.MAP_OF_KING_RANPERRES_TOMB
No, that was what it was before and I'm getting reports for No Message from
players.
…On Sun, May 3, 2020 at 5:09 PM TeoTwawki ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In scripts/zones/Northern_San_dOria/npcs/Aurege.lua
<#558 (comment)>:
> @@ -41,6 +41,7 @@ function onEventFinish(player, csid, option)
if csid == 521 and player:getQuestStatus(SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER) == QUEST_AVAILABLE then
player:addQuest(SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER)
elseif csid == 516 then
- npcUtil.completeQuest(player, SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {ki = tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp = 2000})
+ npcUtil.completeQuest(player, SANDORIA, tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {ki = tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp = 2000 * EXP_RATE})
+ player:messageSpecial(ID.text.KEYITEM_OBTAINED, tpz.ki.MAP_OF_KING_RANPERRES_TOMB) -- Map of King Ranperre's Tomb
npcUtil.completeQuest(player, SANDORIA,
tpz.quest.id.sandoria.EXIT_THE_GAMBLER, {keyItem =
tpz.ki.MAP_OF_KING_RANPERRES_TOMB, title = tpz.title.DAYBREAK_GAMBLER, xp =
2000 * EXP_RATE}) didn't work?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#558 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AJIPZIGHUR5J77FAD3XEHDTRPXMPTANCNFSM4MWY77AA>
.
|
It's always been broken |
I affirm:
Some weren't giving proper rewards or key item notifications. Will push more as we find them.